@extends('layouts.home')
@extends('layouts.nav')
@extends('layouts.top')

@section('heading')
    <h3>
        系统设置
    </h3>
    <ul class="breadcrumb">
        <li>
            <a href="#">系统设置</a>
        </li>
        <li class="active"> 云纯存储</li>
    </ul>
@endsection

@section('wrapper')
    @include('share.error')

    <div class="row">
        <div class="col-sm-12">
            <section class="panel">
                <header class="panel-heading">
                    &nbsp;
                    <span class="tools pull-right">
                            <button class="btn btn-info" onclick='location.href="{{ route('qi-niu-config.create') }}"'
                                    type="button">新增</button>
                    </span>
                </header>
                <div class="panel-body">
                    <table class="table  table-hover general-table">
                        <thead>
                        <tr>
                            <th>名称</th>
                            <th>accessKey</th>
                            <th>secretKey</th>
                            <th>空间名称</th>
                            <th>状态</th>
                            {{--<th>访问地址</th>--}}
                            {{--<th>创建时间</th>--}}
                            <th class="text-center">操作</th>
                        </tr>
                        </thead>
                        <tbody>
                        @foreach($configs as $config)
                            <tr>
                                <td>{{ $config->name }}</td>
                                <td>{{ $config->access_key }}</td>
                                <td>{{ $config->secret_key }}</td>
                                <td>{{ $config->bucket }}</td>
                                <td>{{ $config->status  == 1 ? '有效' : '禁用' }}</td>
                                {{--                                    <td>{{ $config->url }}</td>--}}
                                {{--<td class="numeric">{{ $config->created_at }}</td>--}}
                                <td class="text-center">
                                    <button class="btn btn-success btn-xs" type="button" onclick='location.href="{{ route('qi-niu-config.edit', $config->id) }}"'>编辑</button>
                                </td>
                            </tr>
                        @endforeach


                        </tbody>
                    </table>
                    <div>
                        <ul class="pagination pagination-lg">
                            {{ $configs->links() }}
                        </ul>
                    </div>
                </div>

            </section>
        </div>
    </div>
@endsection